@(user: securesocial.core.java.SocialUser ,message: String,auser: models.User , listOfHospitals: java.util.List[DoctorDetails], doctorDetails: java.util.List[DoctorDetails])
@scripts = {    
	<script type='text/javascript' src="@routes.Assets.at("javascripts/jquery-ui-1.8.23.custom.min.js")"></script>
	<script type='text/javascript' src="@routes.Assets.at("javascripts/fullcalendar_hyperlink.js")"></script>
    <script type="text/javascript" src="@routes.Assets.at("javascripts/jquery.lightbox_me.js")"></script>
    <script type="text/javascript" src="@routes.Assets.at("javascripts/takeappointmentview.js")"></script>
}
@main(user,"Welcome!",scripts) {
 			<div class="toppart">
        		<div class="mainpart">
<!--         			<div id="heading" class="appmentFont"></div>
        			  <div class="hospitaldrowdown">
        		  		<label>
        		  			<strong>Select Hospital:</strong> 
        		  			<select id="hospital" >
        		  			@for(hospital <- doctorDetails ){
        		  			<option value="@hospital.hospital.id">@hospital.hospital.hospitalName</option>
        		  			}
        		  			</select>
        		  		</label>        		
        		</div>
  -->
  <script>
  var hospitals = {hospitals:[]};
  var hospital;
	@for(hospital <- listOfHospitals ){
		hospital = {hospitalid:"@hospital.hospital.id",
					hospitalname: "@hospital.hospital.hospitalName",
					color:""
		};
		hospitals.hospitals.push(hospital);
	}
	  var doctorDayDetails = [];
	  var doctorSchedule1;
		@for(doctorSchedule <- doctorDetails ){
			doctorSchedule1 = {day:"@doctorSchedule.day",
						startTime: "@doctorSchedule.startTime",
						endTime: "@doctorSchedule.endTime",
						hospitalid:"@doctorSchedule.hospital.id",
						hospitalname: "@doctorSchedule.hospital.hospitalName",
			};
			doctorDayDetails.push(doctorSchedule1);
		}	
		console.log(doctorDayDetails);
	
  </script>   
          		  			@for(hospital <- listOfHospitals ){
        		  			<option value="@hospital.hospital.id">@hospital.hospital.hospitalName</option>
        		  			}
        		  	<script>
            		@if(null != auser && auser.userType == "D"){
	    				$(".control").append('<a href="#"><img src="@routes.Assets.at("images/left_panel_login_doctor.png")"></a>');
	    				userType="D";
            		}
            		@if(null != auser && auser.userType != "D"){
  						$(".control").append('<a href="#"><img src="@routes.Assets.at("images/left_panel_login_patient.png")"></a>');
  						userType="P";
            		}  
            		</script>
        			<div id='calendar'></div>
        			<input type="hidden" id="doctorId"/>
        		</div>
	            <div class="modal_window" id="modal_window">
	                <div class="modal_form" id="modal_form">
	                	<label><strong></strong></label>
	                	<input type="hidden" id="appointmenthospitalid" >
	                    <label><strong>Brief Description:</strong> <input id="appointmentdescription" class="sprited"/></label>
	                    <label ><strong>Date:</strong> <input id="appointmentdate" class="firstField smallText" disabled="disabled"/>
	                    <strong>Time:</strong> <input id="appointmenttime" class="smallText" disabled="disabled"/></label>
	                    <label><strong>Additional Information:</strong> <textarea id="appointmentcomments" class="spritedtextarea"></textarea></label>
	                    <div class="actions" id="actions">
							<span class="fc-button fc-button-today ui-state-default ui-corner-left ui-corner-right">
								<span class="fc-button-inner">
									<span id="AppmentSubmit" class="fc-button-content">Submit</span>
									<span class="fc-button-effect">
										<span></span>
									</span>
								</span>
							</span>
	                    </div>
	                </div>
	                <a  id="close_x" class="close close_x" href="#">close</a>
	            </div>

	            <div class="modal_window" id="modal_window_doc">
	                <div class="modal_form" id="modal_form_doc">
	                    <label><strong>Speciality:</strong>
	                    	<select id ="speciality" class="spritedselected">
	                    		<option value="Hematology">Hematology</option>
	                    	</select> 
	                    </label>
	                    <label><strong>Doctor:</strong>
	                    	<select id ="doctorname" class="spritedselected">
	                    		<option value="4">Dr. Vijay Ramanan</option>
	                    	</select> 
	                    </label>
	                    <div class="actions" id="actions">
							<span class="fc-button fc-button-today ui-state-default ui-corner-left ui-corner-right">
								<span class="fc-button-inner">
									<span id="continue" class="fc-button-content">Continue</span>
									<span class="fc-button-effect">
										<span></span>
									</span>
								</span>
							</span>
	                    </div>
	                </div>
	                <a  id="close_x" class="close close_x" href="#">close</a>
	            </div>

	        </div>



    
}